class User < ActiveRecord::Base
  has_many :images
  has_many :matches


  def validate
    errors.add("login","Your login cannot be blank.") if self.login.blank? || self.login.nil?
    errors.add("password","Your passwords did not match, please re-enter them.") if self.password_check.to_s != self.password.to_s
  end

  def password_check=(password)
    @password_check = password
  end

  def  password_check
    @password_check
  end


  # TODO;
  # Add UserType
  # Sessions and Logins
  # Password Hashing
  # ...
end
